# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements.  See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership.  The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License.  You may obtain a copy of the License at
#
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied.  See the License for the
# specific language governing permissions and limitations
# under the License.

from aliyunsdkcore.request import RpcRequest
from aliyunsdkpvtz.endpoint import endpoint_data

class AddResolverEndpointRequest(RpcRequest):

	def __init__(self):
		RpcRequest.__init__(self, 'pvtz', '2018-01-01', 'AddResolverEndpoint','pvtz')
		self.set_method('POST')

		if hasattr(self, "endpoint_map"):
			setattr(self, "endpoint_map", endpoint_data.getEndpointMap())
		if hasattr(self, "endpoint_regional"):
			setattr(self, "endpoint_regional", endpoint_data.getEndpointRegional())

	def get_VpcRegionId(self): # String
		return self.get_query_params().get('VpcRegionId')

	def set_VpcRegionId(self, VpcRegionId):  # String
		self.add_query_param('VpcRegionId', VpcRegionId)
	def get_SecurityGroupId(self): # String
		return self.get_query_params().get('SecurityGroupId')

	def set_SecurityGroupId(self, SecurityGroupId):  # String
		self.add_query_param('SecurityGroupId', SecurityGroupId)
	def get_VpcId(self): # String
		return self.get_query_params().get('VpcId')

	def set_VpcId(self, VpcId):  # String
		self.add_query_param('VpcId', VpcId)
	def get_Name(self): # String
		return self.get_query_params().get('Name')

	def set_Name(self, Name):  # String
		self.add_query_param('Name', Name)
	def get_Lang(self): # String
		return self.get_query_params().get('Lang')

	def set_Lang(self, Lang):  # String
		self.add_query_param('Lang', Lang)
	def get_IpConfigs(self): # RepeatList
		return self.get_query_params().get('IpConfig')

	def set_IpConfigs(self, IpConfig):  # RepeatList
		for depth1 in range(len(IpConfig)):
			if IpConfig[depth1].get('VSwitchId') is not None:
				self.add_query_param('IpConfig.' + str(depth1 + 1) + '.VSwitchId', IpConfig[depth1].get('VSwitchId'))
			if IpConfig[depth1].get('Ip') is not None:
				self.add_query_param('IpConfig.' + str(depth1 + 1) + '.Ip', IpConfig[depth1].get('Ip'))
			if IpConfig[depth1].get('CidrBlock') is not None:
				self.add_query_param('IpConfig.' + str(depth1 + 1) + '.CidrBlock', IpConfig[depth1].get('CidrBlock'))
			if IpConfig[depth1].get('AzId') is not None:
				self.add_query_param('IpConfig.' + str(depth1 + 1) + '.AzId', IpConfig[depth1].get('AzId'))
